package Models

import "time"

/**
 * Created by Goland
 * User: wkk alisleepy@hotmail.com
 * Time: 2023/1/8 - 03:07
 * Desc: <描述信息>
 */

// 员工离职申请状态
const (
	RESIGN_STUTUS_DEFAULT  string = "新建"
	RESIGN_STATUS_PENDING  string = "审批中"
	RESIGN_STATUS_AGREED   string = "同意"
	RESIGN_STATUS_REJECTED string = "驳回"
	RESIGN_STATUS_FINISH   string = "归档"
)

// StaffResign 员工辞职申请
type StaffResign struct {
	Id            int        `json:"id"`
	StaffId       int        `json:"staff_id"`
	Staff         *Staff     `gorm:"FOREIGNKEY:Id; ASSOCIATION_FOREIGNKEY:StaffId" json:"staff"`
	StaffName     string     `json:"staff_name"`
	Status        string     `json:"status"`
	ResignReason  string     `json:"resign_reason"`
	StaffLeftDate time.Time  `json:"staff_left_date"`
	FinalLeftDate time.Time  `json:"final_left_date"`
	CreatedAt     time.Time  `json:"created_at"`
	UpdatedAt     time.Time  `json:"updated_at"`
	DeletedAt     *time.Time `json:"deleted_at;default:null"`
}
